package at.sysarch.bean;

import at.sysarch.domain.TransferImage;
import at.sysarch.filter.Sink.Callback;
import at.sysarch.utils.LinkEvent;
import at.sysarch.utils.LinkListener;

public class Sink extends AbstractBean<at.sysarch.filter.Sink> implements LinkListener, Callback {

	private static final long serialVersionUID = 1L;
	
	public Sink() {
		
		_filter = new at.sysarch.filter.Sink(this);
	}

	@Override
	public void linkBean(LinkEvent event) {
		_filter.setInput(event.getInput());
		event.getInput().setOutput(_filter);
		_filter.run();
	}

	@Override
	public void addLinkListener(LinkListener listener) {
	}

	@Override
	public void removeLinkListener(LinkListener listener) {	
		
	}

	@Override
	public void updateResult(TransferImage result) {
		displayImage(result);
	}
}
